<!-- HTML header for doxygen 1.8.6-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/xhtml;charset=utf-8" http-equiv="Content-Type"/>
<meta content="IE=9" http-equiv="X-UA-Compatible"/>
<meta content="Doxygen 1.8.13" name="generator"/>
<title>OpenCV: High-level GUI</title>
<link href="../../opencv.ico" rel="shortcut icon" type="image/x-icon"/>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script src="../../jquery.js" type="text/javascript"></script>
<script src="../../dynsections.js" type="text/javascript"></script>
<script src="../../tutorial-utils.js" type="text/javascript"></script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script src="../../search/searchdata.js" type="text/javascript"></script>
<script src="../../search/search.js" type="text/javascript"></script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
//<![CDATA[
MathJax.Hub.Config(
{
  TeX: {
      Macros: {
          matTT: [ "\\[ \\left|\\begin{array}{ccc} #1 & #2 & #3\\\\ #4 & #5 & #6\\\\ #7 & #8 & #9 \\end{array}\\right| \\]", 9],
          fork: ["\\left\\{ \\begin{array}{l l} #1 & \\mbox{#2}\\\\ #3 & \\mbox{#4}\\\\ \\end{array} \\right.", 4],
          forkthree: ["\\left\\{ \\begin{array}{l l} #1 & \\mbox{#2}\\\\ #3 & \\mbox{#4}\\\\ #5 & \\mbox{#6}\\\\ \\end{array} \\right.", 6],
          forkfour: ["\\left\\{ \\begin{array}{l l} #1 & \\mbox{#2}\\\\ #3 & \\mbox{#4}\\\\ #5 & \\mbox{#6}\\\\ #7 & \\mbox{#8}\\\\ \\end{array} \\right.", 8],
          vecthree: ["\\begin{bmatrix} #1\\\\ #2\\\\ #3 \\end{bmatrix}", 3],
          vecthreethree: ["\\begin{bmatrix} #1 & #2 & #3\\\\ #4 & #5 & #6\\\\ #7 & #8 & #9 \\end{bmatrix}", 9],
          cameramatrix: ["#1 = \\begin{bmatrix} f_x & 0 & c_x\\\\ 0 & f_y & c_y\\\\ 0 & 0 & 1 \\end{bmatrix}", 1],
          distcoeffs: ["(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6 [, s_1, s_2, s_3, s_4[, \\tau_x, \\tau_y]]]]) \\text{ of 4, 5, 8, 12 or 14 elements}"],
          distcoeffsfisheye: ["(k_1, k_2, k_3, k_4)"],
          hdotsfor: ["\\dots", 1],
          mathbbm: ["\\mathbb{#1}", 1],
          bordermatrix: ["\\matrix{#1}", 1]
      }
  }
}
);
//]]>
</script><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js" type="text/javascript"></script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css"/>
<link href="../../stylesheet.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<!--#include virtual="/google-search.html"-->
<table cellpadding="0" cellspacing="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="../../opencv-logo-small.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">OpenCV
    <span id="projectnumber">4.5.2</span>
   </div>
   <div id="projectbrief">Open Source Computer Vision</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
<script src="../../menudata.js" type="text/javascript"></script>
<script src="../../menu.js" type="text/javascript"></script>
<script type="text/javascript">
$(function() {
  initMenu('../../',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<!-- window showing the filter options -->
<div id="MSearchSelectWindow" onkeydown="return searchBox.OnSearchSelectKey(event)" onmouseout="return searchBox.OnSearchSelectHide()" onmouseover="return searchBox.OnSearchSelectShow()">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe frameborder="0" id="MSearchResults" name="MSearchResults" src="javascript:void(0)">
</iframe>
</div>
<div class="header">
  <div class="summary">
<a href="#groups">Modules</a> |
<a href="#typedef-members">Typedefs</a> |
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">High-level GUI</div>  </div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="groups"></a>
Modules</h2></td></tr>
<tr class="memitem:d0/d90/group__highgui__window__flags"><td align="right" class="memItemLeft" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d0/d90/group__highgui__window__flags.html">Flags related creating and manipulating HighGUI windows and mouse events</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:df/d24/group__highgui__opengl"><td align="right" class="memItemLeft" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../df/d24/group__highgui__opengl.html">OpenGL support</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:dc/d46/group__highgui__qt"><td align="right" class="memItemLeft" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../dc/d46/group__highgui__qt.html">Qt New Functions</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:d6/d2f/group__highgui__winrt"><td align="right" class="memItemLeft" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d6/d2f/group__highgui__winrt.html">WinRT support</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:d0/d28/group__highgui__c"><td align="right" class="memItemLeft" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d0/d28/group__highgui__c.html">C API</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr class="memitem:ga17ffcbb2343dc06e56f980b8414e3566"><td align="right" class="memItemLeft" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga17ffcbb2343dc06e56f980b8414e3566">cv::ButtonCallback</a>) (int state, void *userdata)</td></tr>
<tr class="memdesc:ga17ffcbb2343dc06e56f980b8414e3566"><td class="mdescLeft"> </td><td class="mdescRight">Callback function for a button created by <a class="el" href="../../dc/d46/group__highgui__qt.html#ga938dc3ab0a9f115156439bd380816e2c" title="Attaches a button to the control panel. ">cv::createButton</a>.  <a href="../../d7/dfc/group__highgui.html#ga17ffcbb2343dc06e56f980b8414e3566">More...</a><br/></td></tr>
<tr class="separator:ga17ffcbb2343dc06e56f980b8414e3566"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gab7aed186e151d5222ef97192912127a4"><td align="right" class="memItemLeft" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gab7aed186e151d5222ef97192912127a4">cv::MouseCallback</a>) (int event, int x, int y, int flags, void *userdata)</td></tr>
<tr class="memdesc:gab7aed186e151d5222ef97192912127a4"><td class="mdescLeft"> </td><td class="mdescRight">Callback function for mouse events. see <a class="el" href="../../d7/dfc/group__highgui.html#ga89e7806b0a616f6f1d502bd8c183ad3e" title="Sets mouse handler for the specified window. ">cv::setMouseCallback</a>.  <a href="../../d7/dfc/group__highgui.html#gab7aed186e151d5222ef97192912127a4">More...</a><br/></td></tr>
<tr class="separator:gab7aed186e151d5222ef97192912127a4"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga8bed4feb08f866e81514a31fdacaceee"><td align="right" class="memItemLeft" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga8bed4feb08f866e81514a31fdacaceee">cv::OpenGlDrawCallback</a>) (void *userdata)</td></tr>
<tr class="memdesc:ga8bed4feb08f866e81514a31fdacaceee"><td class="mdescLeft"> </td><td class="mdescRight">Callback function defined to be called every frame. See <a class="el" href="../../df/d24/group__highgui__opengl.html#gaf80dcbc168a6ce40f6d1ad9d79a10bb8" title="Sets a callback function to be called to draw on top of displayed image. ">cv::setOpenGlDrawCallback</a>.  <a href="../../d7/dfc/group__highgui.html#ga8bed4feb08f866e81514a31fdacaceee">More...</a><br/></td></tr>
<tr class="separator:ga8bed4feb08f866e81514a31fdacaceee"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga004b512c3d09aa53f20b050b1d01fab1"><td align="right" class="memItemLeft" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga004b512c3d09aa53f20b050b1d01fab1">cv::TrackbarCallback</a>) (int pos, void *userdata)</td></tr>
<tr class="memdesc:ga004b512c3d09aa53f20b050b1d01fab1"><td class="mdescLeft"> </td><td class="mdescRight">Callback function for Trackbar see <a class="el" href="../../d7/dfc/group__highgui.html#gaf78d2155d30b728fc413803745b67a9b" title="Creates a trackbar and attaches it to the specified window. ">cv::createTrackbar</a>.  <a href="../../d7/dfc/group__highgui.html#ga004b512c3d09aa53f20b050b1d01fab1">More...</a><br/></td></tr>
<tr class="separator:ga004b512c3d09aa53f20b050b1d01fab1"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gaf78d2155d30b728fc413803745b67a9b"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gaf78d2155d30b728fc413803745b67a9b">cv::createTrackbar</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;trackbarname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int *value, int count, <a class="el" href="../../d7/dfc/group__highgui.html#ga004b512c3d09aa53f20b050b1d01fab1">TrackbarCallback</a> onChange=0, void *userdata=0)</td></tr>
<tr class="memdesc:gaf78d2155d30b728fc413803745b67a9b"><td class="mdescLeft"> </td><td class="mdescRight">Creates a trackbar and attaches it to the specified window.  <a href="../../d7/dfc/group__highgui.html#gaf78d2155d30b728fc413803745b67a9b">More...</a><br/></td></tr>
<tr class="separator:gaf78d2155d30b728fc413803745b67a9b"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga6b7fc1c1a8960438156912027b38f481"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga6b7fc1c1a8960438156912027b38f481">cv::destroyAllWindows</a> ()</td></tr>
<tr class="memdesc:ga6b7fc1c1a8960438156912027b38f481"><td class="mdescLeft"> </td><td class="mdescRight">Destroys all of the HighGUI windows.  <a href="../../d7/dfc/group__highgui.html#ga6b7fc1c1a8960438156912027b38f481">More...</a><br/></td></tr>
<tr class="separator:ga6b7fc1c1a8960438156912027b38f481"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga851ccdd6961022d1d5b4c4f255dbab34"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga851ccdd6961022d1d5b4c4f255dbab34">cv::destroyWindow</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname)</td></tr>
<tr class="memdesc:ga851ccdd6961022d1d5b4c4f255dbab34"><td class="mdescLeft"> </td><td class="mdescRight">Destroys the specified window.  <a href="../../d7/dfc/group__highgui.html#ga851ccdd6961022d1d5b4c4f255dbab34">More...</a><br/></td></tr>
<tr class="separator:ga851ccdd6961022d1d5b4c4f255dbab34"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gaedb513e6cf8623a976427be947c53c3f"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gaedb513e6cf8623a976427be947c53c3f">cv::getMouseWheelDelta</a> (int flags)</td></tr>
<tr class="memdesc:gaedb513e6cf8623a976427be947c53c3f"><td class="mdescLeft"> </td><td class="mdescRight">Gets the mouse-wheel motion delta, when handling mouse-wheel events <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gga927593befdddc7e7013602bca9b079b0a402b86eed36ef6cc00cb7425e817af66" title="positive and negative values mean forward and backward scrolling, respectively. ">cv::EVENT_MOUSEWHEEL</a> and <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gga927593befdddc7e7013602bca9b079b0a8c85fc9f3e42b5f4baab925cc5cce753" title="positive and negative values mean right and left scrolling, respectively. ">cv::EVENT_MOUSEHWHEEL</a>.  <a href="../../d7/dfc/group__highgui.html#gaedb513e6cf8623a976427be947c53c3f">More...</a><br/></td></tr>
<tr class="separator:gaedb513e6cf8623a976427be947c53c3f"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga122632e9e91b9ec06943472c55d9cda8"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga122632e9e91b9ec06943472c55d9cda8">cv::getTrackbarPos</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;trackbarname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname)</td></tr>
<tr class="memdesc:ga122632e9e91b9ec06943472c55d9cda8"><td class="mdescLeft"> </td><td class="mdescRight">Returns the trackbar position.  <a href="../../d7/dfc/group__highgui.html#ga122632e9e91b9ec06943472c55d9cda8">More...</a><br/></td></tr>
<tr class="separator:ga122632e9e91b9ec06943472c55d9cda8"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga73b55e9851b5691f6a6a4a4e6c57258e"><td align="right" class="memItemLeft" valign="top"><a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga73b55e9851b5691f6a6a4a4e6c57258e">cv::getWindowImageRect</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname)</td></tr>
<tr class="memdesc:ga73b55e9851b5691f6a6a4a4e6c57258e"><td class="mdescLeft"> </td><td class="mdescRight">Provides rectangle of image in the window.  <a href="../../d7/dfc/group__highgui.html#ga73b55e9851b5691f6a6a4a4e6c57258e">More...</a><br/></td></tr>
<tr class="separator:ga73b55e9851b5691f6a6a4a4e6c57258e"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gaaf9504b8f9cf19024d9d44a14e461656"><td align="right" class="memItemLeft" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gaaf9504b8f9cf19024d9d44a14e461656">cv::getWindowProperty</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int prop_id)</td></tr>
<tr class="memdesc:gaaf9504b8f9cf19024d9d44a14e461656"><td class="mdescLeft"> </td><td class="mdescRight">Provides parameters of a window.  <a href="../../d7/dfc/group__highgui.html#gaaf9504b8f9cf19024d9d44a14e461656">More...</a><br/></td></tr>
<tr class="separator:gaaf9504b8f9cf19024d9d44a14e461656"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga453d42fe4cb60e5723281a89973ee563"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga453d42fe4cb60e5723281a89973ee563">cv::imshow</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, <a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> mat)</td></tr>
<tr class="memdesc:ga453d42fe4cb60e5723281a89973ee563"><td class="mdescLeft"> </td><td class="mdescRight">Displays an image in the specified window.  <a href="../../d7/dfc/group__highgui.html#ga453d42fe4cb60e5723281a89973ee563">More...</a><br/></td></tr>
<tr class="separator:ga453d42fe4cb60e5723281a89973ee563"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga8d86b207f7211250dbe6e28f76307ffb"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga8d86b207f7211250dbe6e28f76307ffb">cv::moveWindow</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int x, int y)</td></tr>
<tr class="memdesc:ga8d86b207f7211250dbe6e28f76307ffb"><td class="mdescLeft"> </td><td class="mdescRight">Moves the window to the specified position.  <a href="../../d7/dfc/group__highgui.html#ga8d86b207f7211250dbe6e28f76307ffb">More...</a><br/></td></tr>
<tr class="separator:ga8d86b207f7211250dbe6e28f76307ffb"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga5afdf8410934fd099df85c75b2e0888b"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga5afdf8410934fd099df85c75b2e0888b">cv::namedWindow</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int flags=<a class="el" href="../../d0/d90/group__highgui__window__flags.html#ggabf7d2c5625bc59ac130287f925557ac3acf621ace7a54954cbac01df27e47228f">WINDOW_AUTOSIZE</a>)</td></tr>
<tr class="memdesc:ga5afdf8410934fd099df85c75b2e0888b"><td class="mdescLeft"> </td><td class="mdescRight">Creates a window.  <a href="../../d7/dfc/group__highgui.html#ga5afdf8410934fd099df85c75b2e0888b">More...</a><br/></td></tr>
<tr class="separator:ga5afdf8410934fd099df85c75b2e0888b"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga6d20fbd3100ec3badc1eaa653aff99d7"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga6d20fbd3100ec3badc1eaa653aff99d7">cv::pollKey</a> ()</td></tr>
<tr class="memdesc:ga6d20fbd3100ec3badc1eaa653aff99d7"><td class="mdescLeft"> </td><td class="mdescRight">Polls for a pressed key.  <a href="../../d7/dfc/group__highgui.html#ga6d20fbd3100ec3badc1eaa653aff99d7">More...</a><br/></td></tr>
<tr class="separator:ga6d20fbd3100ec3badc1eaa653aff99d7"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga9e80e080f7ef33f897e415358aee7f7e"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga9e80e080f7ef33f897e415358aee7f7e">cv::resizeWindow</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int width, int height)</td></tr>
<tr class="memdesc:ga9e80e080f7ef33f897e415358aee7f7e"><td class="mdescLeft"> </td><td class="mdescRight">Resizes the window to the specified size.  <a href="../../d7/dfc/group__highgui.html#ga9e80e080f7ef33f897e415358aee7f7e">More...</a><br/></td></tr>
<tr class="separator:ga9e80e080f7ef33f897e415358aee7f7e"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gab4e70200bf54be967129cf08ac5e18bc"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gab4e70200bf54be967129cf08ac5e18bc">cv::resizeWindow</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga346f563897249351a34549137c8532a0">cv::Size</a> &amp;size)</td></tr>
<tr class="separator:gab4e70200bf54be967129cf08ac5e18bc"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga8daf4730d3adf7035b6de9be4c469af5"><td align="right" class="memItemLeft" valign="top"><a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga8daf4730d3adf7035b6de9be4c469af5">cv::selectROI</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;windowName, <a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> img, bool showCrosshair=true, bool fromCenter=false)</td></tr>
<tr class="memdesc:ga8daf4730d3adf7035b6de9be4c469af5"><td class="mdescLeft"> </td><td class="mdescRight">Allows users to select a ROI on the given image.  <a href="../../d7/dfc/group__highgui.html#ga8daf4730d3adf7035b6de9be4c469af5">More...</a><br/></td></tr>
<tr class="separator:ga8daf4730d3adf7035b6de9be4c469af5"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga2e2256794d0c88f4cfc4fdd7890c9794"><td align="right" class="memItemLeft" valign="top"><a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga2e2256794d0c88f4cfc4fdd7890c9794">cv::selectROI</a> (<a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> img, bool showCrosshair=true, bool fromCenter=false)</td></tr>
<tr class="separator:ga2e2256794d0c88f4cfc4fdd7890c9794"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga0f11fad74a6432b8055fb21621a0f893"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga0f11fad74a6432b8055fb21621a0f893">cv::selectROIs</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;windowName, <a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> img, std::vector&lt; <a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> &gt; &amp;boundingBoxes, bool showCrosshair=true, bool fromCenter=false)</td></tr>
<tr class="memdesc:ga0f11fad74a6432b8055fb21621a0f893"><td class="mdescLeft"> </td><td class="mdescRight">Allows users to select multiple ROIs on the given image.  <a href="../../d7/dfc/group__highgui.html#ga0f11fad74a6432b8055fb21621a0f893">More...</a><br/></td></tr>
<tr class="separator:ga0f11fad74a6432b8055fb21621a0f893"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga89e7806b0a616f6f1d502bd8c183ad3e"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga89e7806b0a616f6f1d502bd8c183ad3e">cv::setMouseCallback</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, <a class="el" href="../../d7/dfc/group__highgui.html#gab7aed186e151d5222ef97192912127a4">MouseCallback</a> onMouse, void *userdata=0)</td></tr>
<tr class="memdesc:ga89e7806b0a616f6f1d502bd8c183ad3e"><td class="mdescLeft"> </td><td class="mdescRight">Sets mouse handler for the specified window.  <a href="../../d7/dfc/group__highgui.html#ga89e7806b0a616f6f1d502bd8c183ad3e">More...</a><br/></td></tr>
<tr class="separator:ga89e7806b0a616f6f1d502bd8c183ad3e"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga7e5437ccba37f1154b65210902fc4480"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga7e5437ccba37f1154b65210902fc4480">cv::setTrackbarMax</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;trackbarname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int maxval)</td></tr>
<tr class="memdesc:ga7e5437ccba37f1154b65210902fc4480"><td class="mdescLeft"> </td><td class="mdescRight">Sets the trackbar maximum position.  <a href="../../d7/dfc/group__highgui.html#ga7e5437ccba37f1154b65210902fc4480">More...</a><br/></td></tr>
<tr class="separator:ga7e5437ccba37f1154b65210902fc4480"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gabe26ffe8d2b60cc678895595a581b7aa"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gabe26ffe8d2b60cc678895595a581b7aa">cv::setTrackbarMin</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;trackbarname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int minval)</td></tr>
<tr class="memdesc:gabe26ffe8d2b60cc678895595a581b7aa"><td class="mdescLeft"> </td><td class="mdescRight">Sets the trackbar minimum position.  <a href="../../d7/dfc/group__highgui.html#gabe26ffe8d2b60cc678895595a581b7aa">More...</a><br/></td></tr>
<tr class="separator:gabe26ffe8d2b60cc678895595a581b7aa"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga67d73c4c9430f13481fd58410d01bd8d"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga67d73c4c9430f13481fd58410d01bd8d">cv::setTrackbarPos</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;trackbarname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int pos)</td></tr>
<tr class="memdesc:ga67d73c4c9430f13481fd58410d01bd8d"><td class="mdescLeft"> </td><td class="mdescRight">Sets the trackbar position.  <a href="../../d7/dfc/group__highgui.html#ga67d73c4c9430f13481fd58410d01bd8d">More...</a><br/></td></tr>
<tr class="separator:ga67d73c4c9430f13481fd58410d01bd8d"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga66e4a6db4d4e06148bcdfe0d70a5df27"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga66e4a6db4d4e06148bcdfe0d70a5df27">cv::setWindowProperty</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, int prop_id, double prop_value)</td></tr>
<tr class="memdesc:ga66e4a6db4d4e06148bcdfe0d70a5df27"><td class="mdescLeft"> </td><td class="mdescRight">Changes parameters of a window dynamically.  <a href="../../d7/dfc/group__highgui.html#ga66e4a6db4d4e06148bcdfe0d70a5df27">More...</a><br/></td></tr>
<tr class="separator:ga66e4a6db4d4e06148bcdfe0d70a5df27"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga56f8849295fd10d0c319724ddb773d96"><td align="right" class="memItemLeft" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga56f8849295fd10d0c319724ddb773d96">cv::setWindowTitle</a> (const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;winname, const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp;title)</td></tr>
<tr class="memdesc:ga56f8849295fd10d0c319724ddb773d96"><td class="mdescLeft"> </td><td class="mdescRight">Updates window title.  <a href="../../d7/dfc/group__highgui.html#ga56f8849295fd10d0c319724ddb773d96">More...</a><br/></td></tr>
<tr class="separator:ga56f8849295fd10d0c319724ddb773d96"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga2c6ecef4f85d8e5cbefec39c9e82ece0"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga2c6ecef4f85d8e5cbefec39c9e82ece0">cv::startWindowThread</a> ()</td></tr>
<tr class="separator:ga2c6ecef4f85d8e5cbefec39c9e82ece0"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga5628525ad33f52eab17feebcfba38bd7"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7">cv::waitKey</a> (int delay=0)</td></tr>
<tr class="memdesc:ga5628525ad33f52eab17feebcfba38bd7"><td class="mdescLeft"> </td><td class="mdescRight">Waits for a pressed key.  <a href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7">More...</a><br/></td></tr>
<tr class="separator:ga5628525ad33f52eab17feebcfba38bd7"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gafa15c0501e0ddd90918f17aa071d3dd0"><td align="right" class="memItemLeft" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dfc/group__highgui.html#gafa15c0501e0ddd90918f17aa071d3dd0">cv::waitKeyEx</a> (int delay=0)</td></tr>
<tr class="memdesc:gafa15c0501e0ddd90918f17aa071d3dd0"><td class="mdescLeft"> </td><td class="mdescRight">Similar to <a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7" title="Waits for a pressed key. ">waitKey</a>, but returns full key code.  <a href="../../d7/dfc/group__highgui.html#gafa15c0501e0ddd90918f17aa071d3dd0">More...</a><br/></td></tr>
<tr class="separator:gafa15c0501e0ddd90918f17aa071d3dd0"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<a id="details" name="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>While OpenCV was designed for use in full-scale applications and can be used within functionally rich UI frameworks (such as Qt*, WinForms*, or Cocoa*) or without any UI at all, sometimes there it is required to try functionality quickly and visualize the results. This is what the HighGUI module has been designed for.</p>
<p>It provides easy interface to:</p>
<ul>
<li>Create and manipulate windows that can display images and "remember" their content (no need to handle repaint events from OS).</li>
<li>Add trackbars to the windows, handle simple mouse events as well as keyboard commands. </li>
</ul>
<h2 class="groupheader">Typedef Documentation</h2>
<a id="ga17ffcbb2343dc06e56f980b8414e3566"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga17ffcbb2343dc06e56f980b8414e3566">◆ </a></span>ButtonCallback</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* cv::ButtonCallback) (int state, void *userdata)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Callback function for a button created by <a class="el" href="../../dc/d46/group__highgui__qt.html#ga938dc3ab0a9f115156439bd380816e2c" title="Attaches a button to the control panel. ">cv::createButton</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">state</td><td>current state of the button. It could be -1 for a push button, 0 or 1 for a check/radio box button. </td></tr>
    <tr><td class="paramname">userdata</td><td>The optional parameter. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="gab7aed186e151d5222ef97192912127a4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gab7aed186e151d5222ef97192912127a4">◆ </a></span>MouseCallback</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* cv::MouseCallback) (int event, int x, int y, int flags, void *userdata)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Callback function for mouse events. see <a class="el" href="../../d7/dfc/group__highgui.html#ga89e7806b0a616f6f1d502bd8c183ad3e" title="Sets mouse handler for the specified window. ">cv::setMouseCallback</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">event</td><td>one of the <a class="el" href="../../d0/d90/group__highgui__window__flags.html#ga927593befdddc7e7013602bca9b079b0" title="Mouse Events see cv::MouseCallback. ">cv::MouseEventTypes</a> constants. </td></tr>
    <tr><td class="paramname">x</td><td>The x-coordinate of the mouse event. </td></tr>
    <tr><td class="paramname">y</td><td>The y-coordinate of the mouse event. </td></tr>
    <tr><td class="paramname">flags</td><td>one of the <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gaab4dc057947f70058c80626c9f1c25ce" title="Mouse Event Flags see cv::MouseCallback. ">cv::MouseEventFlags</a> constants. </td></tr>
    <tr><td class="paramname">userdata</td><td>The optional parameter. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga8bed4feb08f866e81514a31fdacaceee"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8bed4feb08f866e81514a31fdacaceee">◆ </a></span>OpenGlDrawCallback</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* cv::OpenGlDrawCallback) (void *userdata)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Callback function defined to be called every frame. See <a class="el" href="../../df/d24/group__highgui__opengl.html#gaf80dcbc168a6ce40f6d1ad9d79a10bb8" title="Sets a callback function to be called to draw on top of displayed image. ">cv::setOpenGlDrawCallback</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">userdata</td><td>The optional parameter. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga004b512c3d09aa53f20b050b1d01fab1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga004b512c3d09aa53f20b050b1d01fab1">◆ </a></span>TrackbarCallback</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* cv::TrackbarCallback) (int pos, void *userdata)</td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Callback function for Trackbar see <a class="el" href="../../d7/dfc/group__highgui.html#gaf78d2155d30b728fc413803745b67a9b" title="Creates a trackbar and attaches it to the specified window. ">cv::createTrackbar</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pos</td><td>current position of the specified trackbar. </td></tr>
    <tr><td class="paramname">userdata</td><td>The optional parameter. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="gaf78d2155d30b728fc413803745b67a9b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaf78d2155d30b728fc413803745b67a9b">◆ </a></span>createTrackbar()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::createTrackbar </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>trackbarname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int * </td>
          <td class="paramname"><em>value</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>count</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="../../d7/dfc/group__highgui.html#ga004b512c3d09aa53f20b050b1d01fab1">TrackbarCallback</a> </td>
          <td class="paramname"><em>onChange</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void * </td>
          <td class="paramname"><em>userdata</em> = <code>0</code> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Creates a trackbar and attaches it to the specified window. </p>
<p>The function createTrackbar creates a trackbar (a slider or range control) with the specified name and range, assigns a variable value to be a position synchronized with the trackbar and specifies the callback function onChange to be called on the trackbar position change. The created trackbar is displayed in the specified window winname.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>[<b>Qt Backend Only</b>] winname can be empty if the trackbar should be attached to the control panel.</p>
<p>Clicking the label of each trackbar enables editing the trackbar values manually.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">trackbarname</td><td>Name of the created trackbar. </td></tr>
    <tr><td class="paramname">winname</td><td>Name of the window that will be used as a parent of the created trackbar. </td></tr>
    <tr><td class="paramname">value</td><td>Optional pointer to an integer variable whose value reflects the position of the slider. Upon creation, the slider position is defined by this variable. </td></tr>
    <tr><td class="paramname">count</td><td>Maximal position of the slider. The minimal position is always 0. </td></tr>
    <tr><td class="paramname">onChange</td><td>Pointer to the function to be called every time the slider changes position. This function should be prototyped as void Foo(int,void*); , where the first parameter is the trackbar position and the second parameter is the user data (see the next parameter). If the callback is the NULL pointer, no callbacks are called, but only value is updated. </td></tr>
    <tr><td class="paramname">userdata</td><td>User data that is passed as is to the callback. It can be used to handle trackbar events without using global variables. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d6/d7f/samples_2cpp_2camshiftdemo_8cpp-example.html#a26">samples/cpp/camshiftdemo.cpp</a>, <a class="el" href="../../de/d01/samples_2cpp_2connected_components_8cpp-example.html#a18">samples/cpp/connected_components.cpp</a>, <a class="el" href="../../da/d32/samples_2cpp_2contours2_8cpp-example.html#a25">samples/cpp/contours2.cpp</a>, <a class="el" href="../../da/d53/samples_2cpp_2demhist_8cpp-example.html#a26">samples/cpp/demhist.cpp</a>, <a class="el" href="../../d4/dc6/samples_2cpp_2distrans_8cpp-example.html#a23">samples/cpp/distrans.cpp</a>, <a class="el" href="../../d6/d56/samples_2cpp_2edge_8cpp-example.html#a18">samples/cpp/edge.cpp</a>, <a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a29">samples/cpp/falsecolor.cpp</a>, <a class="el" href="../../d1/d17/samples_2cpp_2ffilldemo_8cpp-example.html#a25">samples/cpp/ffilldemo.cpp</a>, <a class="el" href="../../d9/d73/samples_2cpp_2fitellipse_8cpp-example.html#a44">samples/cpp/fitellipse.cpp</a>, <a class="el" href="../../d6/ddf/samples_2cpp_2laplace_8cpp-example.html#a17">samples/cpp/laplace.cpp</a>, <a class="el" href="../../d3/db0/samples_2cpp_2pca_8cpp-example.html#a30">samples/cpp/pca.cpp</a>, <a class="el" href="../../dc/dbc/samples_2cpp_2tutorial_code_2HighGUI_2AddingImagesTrackbar_8cpp-example.html#a8">samples/cpp/tutorial_code/HighGUI/AddingImagesTrackbar.cpp</a>, <a class="el" href="../../d8/ded/samples_2cpp_2tutorial_code_2Histograms_Matching_2MatchTemplate_Demo_8cpp-example.html#a7">samples/cpp/tutorial_code/Histograms_Matching/MatchTemplate_Demo.cpp</a>, <a class="el" href="../../df/d5e/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_1_8cpp-example.html#a10">samples/cpp/tutorial_code/ImgProc/Morphology_1.cpp</a>, <a class="el" href="../../da/d34/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_2_8cpp-example.html#a8">samples/cpp/tutorial_code/ImgProc/Morphology_2.cpp</a>, and <a class="el" href="../../d4/db9/samples_2dnn_2object_detection_8cpp-example.html#a17">samples/dnn/object_detection.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga6b7fc1c1a8960438156912027b38f481"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga6b7fc1c1a8960438156912027b38f481">◆ </a></span>destroyAllWindows()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::destroyAllWindows </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.destroyAllWindows(</td><td class="paramname"></td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Destroys all of the HighGUI windows. </p>
<p>The function destroyAllWindows destroys all of the opened HighGUI windows. </p>
</div>
</div>
<a id="ga851ccdd6961022d1d5b4c4f255dbab34"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga851ccdd6961022d1d5b4c4f255dbab34">◆ </a></span>destroyWindow()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::destroyWindow </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.destroyWindow(</td><td class="paramname">winname</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Destroys the specified window. </p>
<p>The function destroyWindow destroys the window with the given name.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window to be destroyed. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d0/d38/modules_2shape_2samples_2shape_example_8cpp-example.html#a21">modules/shape/samples/shape_example.cpp</a>, <a class="el" href="../../d6/d7f/samples_2cpp_2camshiftdemo_8cpp-example.html#a65">samples/cpp/camshiftdemo.cpp</a>, <a class="el" href="../../d1/d17/samples_2cpp_2ffilldemo_8cpp-example.html#a29">samples/cpp/ffilldemo.cpp</a>, and <a class="el" href="../../d8/d34/samples_2cpp_2grabcut_8cpp-example.html#a48">samples/cpp/grabcut.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="gaedb513e6cf8623a976427be947c53c3f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaedb513e6cf8623a976427be947c53c3f">◆ </a></span>getMouseWheelDelta()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::getMouseWheelDelta </td>
          <td>(</td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>flags</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Gets the mouse-wheel motion delta, when handling mouse-wheel events <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gga927593befdddc7e7013602bca9b079b0a402b86eed36ef6cc00cb7425e817af66" title="positive and negative values mean forward and backward scrolling, respectively. ">cv::EVENT_MOUSEWHEEL</a> and <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gga927593befdddc7e7013602bca9b079b0a8c85fc9f3e42b5f4baab925cc5cce753" title="positive and negative values mean right and left scrolling, respectively. ">cv::EVENT_MOUSEHWHEEL</a>. </p>
<p>For regular mice with a scroll-wheel, delta will be a multiple of 120. The value 120 corresponds to a one notch rotation of the wheel or the threshold for action to be taken and one such action should occur for each delta. Some high-precision mice with higher-resolution freely-rotating wheels may generate smaller values.</p>
<p>For <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gga927593befdddc7e7013602bca9b079b0a402b86eed36ef6cc00cb7425e817af66" title="positive and negative values mean forward and backward scrolling, respectively. ">cv::EVENT_MOUSEWHEEL</a> positive and negative values mean forward and backward scrolling, respectively. For <a class="el" href="../../d0/d90/group__highgui__window__flags.html#gga927593befdddc7e7013602bca9b079b0a8c85fc9f3e42b5f4baab925cc5cce753" title="positive and negative values mean right and left scrolling, respectively. ">cv::EVENT_MOUSEHWHEEL</a>, where available, positive and negative values mean right and left scrolling, respectively.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>Mouse-wheel events are currently supported only on Windows.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">flags</td><td>The mouse callback flags parameter. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga122632e9e91b9ec06943472c55d9cda8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga122632e9e91b9ec06943472c55d9cda8">◆ </a></span>getTrackbarPos()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::getTrackbarPos </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>trackbarname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.getTrackbarPos(</td><td class="paramname">trackbarname, winname</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Returns the trackbar position. </p>
<p>The function returns the current position of the specified trackbar.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>[<b>Qt Backend Only</b>] winname can be empty if the trackbar is attached to the control panel.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">trackbarname</td><td>Name of the trackbar. </td></tr>
    <tr><td class="paramname">winname</td><td>Name of the window that is the parent of the trackbar. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga73b55e9851b5691f6a6a4a4e6c57258e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga73b55e9851b5691f6a6a4a4e6c57258e">◆ </a></span>getWindowImageRect()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> cv::getWindowImageRect </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.getWindowImageRect(</td><td class="paramname">winname</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Provides rectangle of image in the window. </p>
<p>The function getWindowImageRect returns the client screen coordinates, width and height of the image rendering area.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="../../d7/dfc/group__highgui.html#ga9e80e080f7ef33f897e415358aee7f7e" title="Resizes the window to the specified size. ">resizeWindow</a> <a class="el" href="../../d7/dfc/group__highgui.html#ga8d86b207f7211250dbe6e28f76307ffb" title="Moves the window to the specified position. ">moveWindow</a> </dd></dl>
</div>
</div>
<a id="gaaf9504b8f9cf19024d9d44a14e461656"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaaf9504b8f9cf19024d9d44a14e461656">◆ </a></span>getWindowProperty()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double cv::getWindowProperty </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>prop_id</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.getWindowProperty(</td><td class="paramname">winname, prop_id</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Provides parameters of a window. </p>
<p>The function getWindowProperty returns properties of a window.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window. </td></tr>
    <tr><td class="paramname">prop_id</td><td>Window property to retrieve. The following operation flags are available: (<a class="el" href="../../d0/d90/group__highgui__window__flags.html#gaeedf4023e777f896ba6b9ffb156f57b8" title="Flags for cv::setWindowProperty / cv::getWindowProperty. ">cv::WindowPropertyFlags</a>)</td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="../../d7/dfc/group__highgui.html#ga66e4a6db4d4e06148bcdfe0d70a5df27" title="Changes parameters of a window dynamically. ">setWindowProperty</a> </dd></dl>
</div>
</div>
<a id="ga453d42fe4cb60e5723281a89973ee563"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga453d42fe4cb60e5723281a89973ee563">◆ </a></span>imshow()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::imshow </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> </td>
          <td class="paramname"><em>mat</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.imshow(</td><td class="paramname">winname, mat</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Displays an image in the specified window. </p>
<p>The function imshow displays an image in the specified window. If the window was created with the <a class="el" href="../../d0/d90/group__highgui__window__flags.html#ggabf7d2c5625bc59ac130287f925557ac3acf621ace7a54954cbac01df27e47228f" title="the user cannot resize the window, the size is constrainted by the image displayed. ">cv::WINDOW_AUTOSIZE</a> flag, the image is shown with its original size, however it is still limited by the screen resolution. Otherwise, the image is scaled to fit the window. The function may scale the image, depending on its depth:</p>
<ul>
<li>If the image is 8-bit unsigned, it is displayed as is.</li>
<li>If the image is 16-bit unsigned or 32-bit integer, the pixels are divided by 256. That is, the value range [0,255*256] is mapped to [0,255].</li>
<li>If the image is 32-bit or 64-bit floating-point, the pixel values are multiplied by 255. That is, the value range [0,1] is mapped to [0,255].</li>
</ul>
<p>If window was created with OpenGL support, <a class="el" href="../../d7/dfc/group__highgui.html#ga453d42fe4cb60e5723281a89973ee563" title="Displays an image in the specified window. ">cv::imshow</a> also support <a class="el" href="../../d3/d68/classcv_1_1ogl_1_1Buffer.html" title="Smart pointer for OpenGL buffer object with reference counting. ">ogl::Buffer</a> , <a class="el" href="../../d5/ddf/classcv_1_1ogl_1_1Texture2D.html" title="Smart pointer for OpenGL 2D texture memory with reference counting. ">ogl::Texture2D</a> and <a class="el" href="../../d0/d60/classcv_1_1cuda_1_1GpuMat.html" title="Base storage class for GPU memory with reference counting. ">cuda::GpuMat</a> as input.</p>
<p>If the window was not created before this function, it is assumed creating a window with <a class="el" href="../../d0/d90/group__highgui__window__flags.html#ggabf7d2c5625bc59ac130287f925557ac3acf621ace7a54954cbac01df27e47228f" title="the user cannot resize the window, the size is constrainted by the image displayed. ">cv::WINDOW_AUTOSIZE</a>.</p>
<p>If you need to show an image that is bigger than the screen resolution, you will need to call namedWindow("", WINDOW_NORMAL) before the imshow.</p>
<dl class="section note"><dt>Note</dt><dd>This function should be followed by a call to <a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7" title="Waits for a pressed key. ">cv::waitKey</a> or <a class="el" href="../../d7/dfc/group__highgui.html#ga6d20fbd3100ec3badc1eaa653aff99d7" title="Polls for a pressed key. ">cv::pollKey</a> to perform GUI housekeeping tasks that are necessary to actually show the given image and make the window respond to mouse and keyboard events. Otherwise, it won't display the image and the window might lock up. For example, <b>waitKey(0)</b> will display the window infinitely until any keypress (it is suitable for image display). <b>waitKey(25)</b> will display a frame and wait approximately 25 ms for a key press (suitable for displaying a video frame-by-frame). To remove the window, use <a class="el" href="../../d7/dfc/group__highgui.html#ga851ccdd6961022d1d5b4c4f255dbab34" title="Destroys the specified window. ">cv::destroyWindow</a>.</dd>
<dd>
</dd></dl>
<p>[<b>Windows Backend Only</b>] Pressing Ctrl+C will copy the image to the clipboard.</p>
<p>[<b>Windows Backend Only</b>] Pressing Ctrl+S will show a dialog to save the image.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window. </td></tr>
    <tr><td class="paramname">mat</td><td>Image to be shown. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d1/d9e/fld_lines_8cpp-example.html#a12">fld_lines.cpp</a>, <a class="el" href="../../d0/d38/modules_2shape_2samples_2shape_example_8cpp-example.html#a17">modules/shape/samples/shape_example.cpp</a>, <a class="el" href="../../d6/d7f/samples_2cpp_2camshiftdemo_8cpp-example.html#a63">samples/cpp/camshiftdemo.cpp</a>, <a class="el" href="../../de/d01/samples_2cpp_2connected_components_8cpp-example.html#a8">samples/cpp/connected_components.cpp</a>, <a class="el" href="../../da/d32/samples_2cpp_2contours2_8cpp-example.html#a7">samples/cpp/contours2.cpp</a>, <a class="el" href="../../d5/d04/samples_2cpp_2convexhull_8cpp-example.html#a19">samples/cpp/convexhull.cpp</a>, <a class="el" href="../../db/d75/samples_2cpp_2create_mask_8cpp-example.html#a9">samples/cpp/create_mask.cpp</a>, <a class="el" href="../../da/d53/samples_2cpp_2demhist_8cpp-example.html#a3">samples/cpp/demhist.cpp</a>, <a class="el" href="../../d4/dc6/samples_2cpp_2distrans_8cpp-example.html#a16">samples/cpp/distrans.cpp</a>, <a class="el" href="../../d6/d56/samples_2cpp_2edge_8cpp-example.html#a6">samples/cpp/edge.cpp</a>, <a class="el" href="../../d4/d26/samples_2cpp_2facedetect_8cpp-example.html#a48">samples/cpp/facedetect.cpp</a>, <a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a9">samples/cpp/falsecolor.cpp</a>, <a class="el" href="../../d1/d17/samples_2cpp_2ffilldemo_8cpp-example.html#a13">samples/cpp/ffilldemo.cpp</a>, <a class="el" href="../../d9/d73/samples_2cpp_2fitellipse_8cpp-example.html#a41">samples/cpp/fitellipse.cpp</a>, <a class="el" href="../../d8/d34/samples_2cpp_2grabcut_8cpp-example.html#a23">samples/cpp/grabcut.cpp</a>, <a class="el" href="../../dd/d93/samples_2cpp_2image_alignment_8cpp-example.html#a51">samples/cpp/image_alignment.cpp</a>, <a class="el" href="../../df/da5/samples_2cpp_2intersectExample_8cpp-example.html#a16">samples/cpp/intersectExample.cpp</a>, <a class="el" href="../../de/d70/samples_2cpp_2kalman_8cpp-example.html#a30">samples/cpp/kalman.cpp</a>, <a class="el" href="../../d9/dde/samples_2cpp_2kmeans_8cpp-example.html#a28">samples/cpp/kmeans.cpp</a>, <a class="el" href="../../d6/ddf/samples_2cpp_2laplace_8cpp-example.html#a26">samples/cpp/laplace.cpp</a>, <a class="el" href="../../d2/d1d/samples_2cpp_2lkdemo_8cpp-example.html#a29">samples/cpp/lkdemo.cpp</a>, <a class="el" href="../../df/dee/samples_2cpp_2minarea_8cpp-example.html#a24">samples/cpp/minarea.cpp</a>, <a class="el" href="../../d3/db0/samples_2cpp_2pca_8cpp-example.html#a18">samples/cpp/pca.cpp</a>, <a class="el" href="../../df/d54/samples_2cpp_2peopledetect_8cpp-example.html#a35">samples/cpp/peopledetect.cpp</a>, <a class="el" href="../../d4/d35/samples_2cpp_2polar_transforms_8cpp-example.html#a35">samples/cpp/polar_transforms.cpp</a>, <a class="el" href="../../d5/de8/samples_2cpp_2segment_objects_8cpp-example.html#a24">samples/cpp/segment_objects.cpp</a>, <a class="el" href="../../db/d00/samples_2cpp_2squares_8cpp-example.html#a32">samples/cpp/squares.cpp</a>, <a class="el" href="../../d0/df8/samples_2cpp_2train_HOG_8cpp-example.html#a19">samples/cpp/train_HOG.cpp</a>, <a class="el" href="../../d9/d47/samples_2cpp_2tutorial_code_2features2D_2Homography_2homography_from_camera_displacement_8cpp-example.html#a16">samples/cpp/tutorial_code/features2D/Homography/homography_from_camera_displacement.cpp</a>, <a class="el" href="../../d0/d92/samples_2cpp_2tutorial_code_2features2D_2Homography_2pose_from_homography_8cpp-example.html#a12">samples/cpp/tutorial_code/features2D/Homography/pose_from_homography.cpp</a>, <a class="el" href="../../dc/dbc/samples_2cpp_2tutorial_code_2HighGUI_2AddingImagesTrackbar_8cpp-example.html#a2">samples/cpp/tutorial_code/HighGUI/AddingImagesTrackbar.cpp</a>, <a class="el" href="../../d8/ded/samples_2cpp_2tutorial_code_2Histograms_Matching_2MatchTemplate_Demo_8cpp-example.html#a26">samples/cpp/tutorial_code/Histograms_Matching/MatchTemplate_Demo.cpp</a>, <a class="el" href="../../d2/dda/samples_2cpp_2tutorial_code_2ImgProc_2basic_drawing_2Drawing_1_8cpp-example.html#a9">samples/cpp/tutorial_code/ImgProc/basic_drawing/Drawing_1.cpp</a>, <a class="el" href="../../de/d06/samples_2cpp_2tutorial_code_2ImgProc_2basic_drawing_2Drawing_2_8cpp-example.html#a5">samples/cpp/tutorial_code/ImgProc/basic_drawing/Drawing_2.cpp</a>, <a class="el" href="../../df/d5e/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_1_8cpp-example.html#a19">samples/cpp/tutorial_code/ImgProc/Morphology_1.cpp</a>, <a class="el" href="../../da/d34/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_2_8cpp-example.html#a14">samples/cpp/tutorial_code/ImgProc/Morphology_2.cpp</a>, <a class="el" href="../../d3/d08/samples_2cpp_2tutorial_code_2ImgProc_2Pyramids_2Pyramids_8cpp-example.html#a4">samples/cpp/tutorial_code/ImgProc/Pyramids/Pyramids.cpp</a>, <a class="el" href="../../d3/d8f/samples_2cpp_2tutorial_code_2ImgProc_2Smoothing_2Smoothing_8cpp-example.html#a21">samples/cpp/tutorial_code/ImgProc/Smoothing/Smoothing.cpp</a>, <a class="el" href="../../d6/d14/samples_2cpp_2tutorial_code_2ImgTrans_2copyMakeBorder_demo_8cpp-example.html#a13">samples/cpp/tutorial_code/ImgTrans/copyMakeBorder_demo.cpp</a>, <a class="el" href="../../d1/de6/samples_2cpp_2tutorial_code_2ImgTrans_2houghcircles_8cpp-example.html#a17">samples/cpp/tutorial_code/ImgTrans/houghcircles.cpp</a>, <a class="el" href="../../d5/df9/samples_2cpp_2tutorial_code_2ImgTrans_2houghlines_8cpp-example.html#a23">samples/cpp/tutorial_code/ImgTrans/houghlines.cpp</a>, <a class="el" href="../../d3/d94/samples_2cpp_2tutorial_code_2ImgTrans_2Sobel_Demo_8cpp-example.html#a17">samples/cpp/tutorial_code/ImgTrans/Sobel_Demo.cpp</a>, <a class="el" href="../../da/d94/samples_2cpp_2tutorial_code_2ml_2introduction_to_pca_2introduction_to_pca_8cpp-example.html#a26">samples/cpp/tutorial_code/ml/introduction_to_pca/introduction_to_pca.cpp</a>, <a class="el" href="../../de/dd9/samples_2cpp_2tutorial_code_2photo_2non_photorealistic_rendering_2npr_demo_8cpp-example.html#a8">samples/cpp/tutorial_code/photo/non_photorealistic_rendering/npr_demo.cpp</a>, <a class="el" href="../../dc/d23/samples_2cpp_2tutorial_code_2photo_2seamless_cloning_2cloning_demo_8cpp-example.html#a9">samples/cpp/tutorial_code/photo/seamless_cloning/cloning_demo.cpp</a>, <a class="el" href="../../df/d94/samples_2cpp_2videowriter_basic_8cpp-example.html#a10">samples/cpp/videowriter_basic.cpp</a>, <a class="el" href="../../de/dd4/samples_2cpp_2warpPerspective_demo_8cpp-example.html#a21">samples/cpp/warpPerspective_demo.cpp</a>, <a class="el" href="../../d4/d40/samples_2cpp_2watershed_8cpp-example.html#a12">samples/cpp/watershed.cpp</a>, <a class="el" href="../../d9/d8d/samples_2dnn_2classification_8cpp-example.html#a36">samples/dnn/classification.cpp</a>, <a class="el" href="../../d6/d39/samples_2dnn_2colorization_8cpp-example.html#a27">samples/dnn/colorization.cpp</a>, <a class="el" href="../../d4/db9/samples_2dnn_2object_detection_8cpp-example.html#a29">samples/dnn/object_detection.cpp</a>, <a class="el" href="../../d7/d4f/samples_2dnn_2openpose_8cpp-example.html#a27">samples/dnn/openpose.cpp</a>, <a class="el" href="../../d4/d88/samples_2dnn_2segmentation_8cpp-example.html#a28">samples/dnn/segmentation.cpp</a>, <a class="el" href="../../db/da4/samples_2dnn_2text_detection_8cpp-example.html#a20">samples/dnn/text_detection.cpp</a>, <a class="el" href="../../d8/d61/samples_2tapi_2hog_8cpp-example.html#a37">samples/tapi/hog.cpp</a>, and <a class="el" href="../../de/dc0/samples_2tapi_2squares_8cpp-example.html#a49">samples/tapi/squares.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga8d86b207f7211250dbe6e28f76307ffb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8d86b207f7211250dbe6e28f76307ffb">◆ </a></span>moveWindow()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::moveWindow </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>y</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.moveWindow(</td><td class="paramname">winname, x, y</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Moves the window to the specified position. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window. </td></tr>
    <tr><td class="paramname">x</td><td>The new x-coordinate of the window. </td></tr>
    <tr><td class="paramname">y</td><td>The new y-coordinate of the window. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d0/d38/modules_2shape_2samples_2shape_example_8cpp-example.html#a18">modules/shape/samples/shape_example.cpp</a>, <a class="el" href="../../dd/d93/samples_2cpp_2image_alignment_8cpp-example.html#a48">samples/cpp/image_alignment.cpp</a>, <a class="el" href="../../d4/d35/samples_2cpp_2polar_transforms_8cpp-example.html#a11">samples/cpp/polar_transforms.cpp</a>, <a class="el" href="../../d2/dda/samples_2cpp_2tutorial_code_2ImgProc_2basic_drawing_2Drawing_1_8cpp-example.html#a10">samples/cpp/tutorial_code/ImgProc/basic_drawing/Drawing_1.cpp</a>, <a class="el" href="../../df/d5e/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_1_8cpp-example.html#a8">samples/cpp/tutorial_code/ImgProc/Morphology_1.cpp</a>, and <a class="el" href="../../de/dd4/samples_2cpp_2warpPerspective_demo_8cpp-example.html#a13">samples/cpp/warpPerspective_demo.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga5afdf8410934fd099df85c75b2e0888b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga5afdf8410934fd099df85c75b2e0888b">◆ </a></span>namedWindow()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::namedWindow </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>flags</em> = <code><a class="el" href="../../d0/d90/group__highgui__window__flags.html#ggabf7d2c5625bc59ac130287f925557ac3acf621ace7a54954cbac01df27e47228f">WINDOW_AUTOSIZE</a></code> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.namedWindow(</td><td class="paramname">winname[, flags]</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Creates a window. </p>
<p>The function namedWindow creates a window that can be used as a placeholder for images and trackbars. Created windows are referred to by their names.</p>
<p>If a window with the same name already exists, the function does nothing.</p>
<p>You can call <a class="el" href="../../d7/dfc/group__highgui.html#ga851ccdd6961022d1d5b4c4f255dbab34" title="Destroys the specified window. ">cv::destroyWindow</a> or <a class="el" href="../../d7/dfc/group__highgui.html#ga6b7fc1c1a8960438156912027b38f481" title="Destroys all of the HighGUI windows. ">cv::destroyAllWindows</a> to close the window and de-allocate any associated memory usage. For a simple program, you do not really have to call these functions because all the resources and windows of the application are closed automatically by the operating system upon exit.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>Qt backend supports additional flags:</p><ul>
<li><b>WINDOW_NORMAL or WINDOW_AUTOSIZE:</b> WINDOW_NORMAL enables you to resize the window, whereas WINDOW_AUTOSIZE adjusts automatically the window size to fit the displayed image (see imshow ), and you cannot change the window size manually.</li>
<li><b>WINDOW_FREERATIO or WINDOW_KEEPRATIO:</b> WINDOW_FREERATIO adjusts the image with no respect to its ratio, whereas WINDOW_KEEPRATIO keeps the image ratio.</li>
<li><b>WINDOW_GUI_NORMAL or WINDOW_GUI_EXPANDED:</b> WINDOW_GUI_NORMAL is the old way to draw the window without statusbar and toolbar, whereas WINDOW_GUI_EXPANDED is a new enhanced GUI. By default, flags == WINDOW_AUTOSIZE | WINDOW_KEEPRATIO | WINDOW_GUI_EXPANDED</li>
</ul>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window in the window caption that may be used as a window identifier. </td></tr>
    <tr><td class="paramname">flags</td><td>Flags of the window. The supported flags are: (<a class="el" href="../../d0/d90/group__highgui__window__flags.html#gabf7d2c5625bc59ac130287f925557ac3" title="Flags for cv::namedWindow. ">cv::WindowFlags</a>) </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d6/d7f/samples_2cpp_2camshiftdemo_8cpp-example.html#a24">samples/cpp/camshiftdemo.cpp</a>, <a class="el" href="../../de/d01/samples_2cpp_2connected_components_8cpp-example.html#a16">samples/cpp/connected_components.cpp</a>, <a class="el" href="../../da/d32/samples_2cpp_2contours2_8cpp-example.html#a20">samples/cpp/contours2.cpp</a>, <a class="el" href="../../db/d75/samples_2cpp_2create_mask_8cpp-example.html#a23">samples/cpp/create_mask.cpp</a>, <a class="el" href="../../da/d53/samples_2cpp_2demhist_8cpp-example.html#a25">samples/cpp/demhist.cpp</a>, <a class="el" href="../../d4/dc6/samples_2cpp_2distrans_8cpp-example.html#a22">samples/cpp/distrans.cpp</a>, <a class="el" href="../../d6/d56/samples_2cpp_2edge_8cpp-example.html#a17">samples/cpp/edge.cpp</a>, <a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a28">samples/cpp/falsecolor.cpp</a>, <a class="el" href="../../d1/d17/samples_2cpp_2ffilldemo_8cpp-example.html#a24">samples/cpp/ffilldemo.cpp</a>, <a class="el" href="../../d9/d73/samples_2cpp_2fitellipse_8cpp-example.html#a42">samples/cpp/fitellipse.cpp</a>, <a class="el" href="../../d8/d34/samples_2cpp_2grabcut_8cpp-example.html#a44">samples/cpp/grabcut.cpp</a>, <a class="el" href="../../dd/d93/samples_2cpp_2image_alignment_8cpp-example.html#a46">samples/cpp/image_alignment.cpp</a>, <a class="el" href="../../d6/ddf/samples_2cpp_2laplace_8cpp-example.html#a15">samples/cpp/laplace.cpp</a>, <a class="el" href="../../d2/d1d/samples_2cpp_2lkdemo_8cpp-example.html#a13">samples/cpp/lkdemo.cpp</a>, <a class="el" href="../../d3/db0/samples_2cpp_2pca_8cpp-example.html#a28">samples/cpp/pca.cpp</a>, <a class="el" href="../../d4/d35/samples_2cpp_2polar_transforms_8cpp-example.html#a9">samples/cpp/polar_transforms.cpp</a>, <a class="el" href="../../d5/de8/samples_2cpp_2segment_objects_8cpp-example.html#a22">samples/cpp/segment_objects.cpp</a>, <a class="el" href="../../d0/df8/samples_2cpp_2train_HOG_8cpp-example.html#a40">samples/cpp/train_HOG.cpp</a>, <a class="el" href="../../dc/dbc/samples_2cpp_2tutorial_code_2HighGUI_2AddingImagesTrackbar_8cpp-example.html#a6">samples/cpp/tutorial_code/HighGUI/AddingImagesTrackbar.cpp</a>, <a class="el" href="../../d8/ded/samples_2cpp_2tutorial_code_2Histograms_Matching_2MatchTemplate_Demo_8cpp-example.html#a5">samples/cpp/tutorial_code/Histograms_Matching/MatchTemplate_Demo.cpp</a>, <a class="el" href="../../df/d5e/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_1_8cpp-example.html#a6">samples/cpp/tutorial_code/ImgProc/Morphology_1.cpp</a>, <a class="el" href="../../da/d34/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_2_8cpp-example.html#a6">samples/cpp/tutorial_code/ImgProc/Morphology_2.cpp</a>, <a class="el" href="../../d3/d8f/samples_2cpp_2tutorial_code_2ImgProc_2Smoothing_2Smoothing_8cpp-example.html#a1">samples/cpp/tutorial_code/ImgProc/Smoothing/Smoothing.cpp</a>, <a class="el" href="../../d6/d14/samples_2cpp_2tutorial_code_2ImgTrans_2copyMakeBorder_demo_8cpp-example.html#a7">samples/cpp/tutorial_code/ImgTrans/copyMakeBorder_demo.cpp</a>, <a class="el" href="../../de/dd4/samples_2cpp_2warpPerspective_demo_8cpp-example.html#a10">samples/cpp/warpPerspective_demo.cpp</a>, <a class="el" href="../../d4/d40/samples_2cpp_2watershed_8cpp-example.html#a19">samples/cpp/watershed.cpp</a>, <a class="el" href="../../d9/d8d/samples_2dnn_2classification_8cpp-example.html#a17">samples/dnn/classification.cpp</a>, <a class="el" href="../../d4/db9/samples_2dnn_2object_detection_8cpp-example.html#a15">samples/dnn/object_detection.cpp</a>, <a class="el" href="../../d4/d88/samples_2dnn_2segmentation_8cpp-example.html#a12">samples/dnn/segmentation.cpp</a>, and <a class="el" href="../../de/dc0/samples_2tapi_2squares_8cpp-example.html#a41">samples/tapi/squares.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga6d20fbd3100ec3badc1eaa653aff99d7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga6d20fbd3100ec3badc1eaa653aff99d7">◆ </a></span>pollKey()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::pollKey </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.pollKey(</td><td class="paramname"></td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Polls for a pressed key. </p>
<p>The function pollKey polls for a key event without waiting. It returns the code of the pressed key or -1 if no key was pressed since the last invocation. To wait until a key was pressed, use <a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7" title="Waits for a pressed key. ">waitKey</a>.</p>
<dl class="section note"><dt>Note</dt><dd>The functions <a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7" title="Waits for a pressed key. ">waitKey</a> and <a class="el" href="../../d7/dfc/group__highgui.html#ga6d20fbd3100ec3badc1eaa653aff99d7" title="Polls for a pressed key. ">pollKey</a> are the only methods in HighGUI that can fetch and handle GUI events, so one of them needs to be called periodically for normal event processing unless HighGUI is used within an environment that takes care of event processing.</dd>
<dd>
The function only works if there is at least one HighGUI window created and the window is active. If there are several HighGUI windows, any of them can be active. </dd></dl>
</div>
</div>
<a id="ga9e80e080f7ef33f897e415358aee7f7e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga9e80e080f7ef33f897e415358aee7f7e">◆ </a></span>resizeWindow() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::resizeWindow </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>height</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.resizeWindow(</td><td class="paramname">winname, width, height</td><td>)</td></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.resizeWindow(</td><td class="paramname">winname, size</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Resizes the window to the specified size. </p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<ul>
<li>The specified window size is for the image area. Toolbars are not counted.</li>
<li>Only windows created without <a class="el" href="../../d0/d90/group__highgui__window__flags.html#ggabf7d2c5625bc59ac130287f925557ac3acf621ace7a54954cbac01df27e47228f" title="the user cannot resize the window, the size is constrainted by the image displayed. ">cv::WINDOW_AUTOSIZE</a> flag can be resized.</li>
</ul>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Window name. </td></tr>
    <tr><td class="paramname">width</td><td>The new window width. </td></tr>
    <tr><td class="paramname">height</td><td>The new window height. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="gab4e70200bf54be967129cf08ac5e18bc"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gab4e70200bf54be967129cf08ac5e18bc">◆ </a></span>resizeWindow() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::resizeWindow </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga346f563897249351a34549137c8532a0">cv::Size</a> &amp; </td>
          <td class="paramname"><em>size</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.resizeWindow(</td><td class="paramname">winname, width, height</td><td>)</td></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.resizeWindow(</td><td class="paramname">winname, size</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Window name. </td></tr>
    <tr><td class="paramname">size</td><td>The new window size. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga8daf4730d3adf7035b6de9be4c469af5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8daf4730d3adf7035b6de9be4c469af5">◆ </a></span>selectROI() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> cv::selectROI </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>windowName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> </td>
          <td class="paramname"><em>img</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool </td>
          <td class="paramname"><em>showCrosshair</em> = <code>true</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool </td>
          <td class="paramname"><em>fromCenter</em> = <code>false</code> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.selectROI(</td><td class="paramname">windowName, img[, showCrosshair[, fromCenter]]</td><td>)</td></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.selectROI(</td><td class="paramname">img[, showCrosshair[, fromCenter]]</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Allows users to select a ROI on the given image. </p>
<p>The function creates a window and allows users to select a ROI using the mouse. Controls: use <code>space</code> or <code>enter</code> to finish selection, use key <code>c</code> to cancel selection (function will return the zero <a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">cv::Rect</a>).</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">windowName</td><td>name of the window where selection process will be shown. </td></tr>
    <tr><td class="paramname">img</td><td>image to select a ROI. </td></tr>
    <tr><td class="paramname">showCrosshair</td><td>if true crosshair of selection rectangle will be shown. </td></tr>
    <tr><td class="paramname">fromCenter</td><td>if true center of selection will match initial mouse position. In opposite case a corner of selection rectangle will correspont to the initial mouse position. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>selected ROI or empty rect if selection canceled.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>The function sets it's own mouse callback for specified window using <a class="el" href="../../d7/dfc/group__highgui.html#ga89e7806b0a616f6f1d502bd8c183ad3e" title="Sets mouse handler for the specified window. ">cv::setMouseCallback</a>(windowName, ...). After finish of work an empty callback will be set for the used window. </dd></dl>
</div>
</div>
<a id="ga2e2256794d0c88f4cfc4fdd7890c9794"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga2e2256794d0c88f4cfc4fdd7890c9794">◆ </a></span>selectROI() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> cv::selectROI </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> </td>
          <td class="paramname"><em>img</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool </td>
          <td class="paramname"><em>showCrosshair</em> = <code>true</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool </td>
          <td class="paramname"><em>fromCenter</em> = <code>false</code> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.selectROI(</td><td class="paramname">windowName, img[, showCrosshair[, fromCenter]]</td><td>)</td></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.selectROI(</td><td class="paramname">img[, showCrosshair[, fromCenter]]</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
</div>
</div>
<a id="ga0f11fad74a6432b8055fb21621a0f893"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga0f11fad74a6432b8055fb21621a0f893">◆ </a></span>selectROIs()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::selectROIs </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>windowName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="../../dc/d84/group__core__basic.html#ga353a9de602fe76c709e12074a6f362ba">InputArray</a> </td>
          <td class="paramname"><em>img</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::vector&lt; <a class="el" href="../../dc/d84/group__core__basic.html#ga11d95de507098e90bad732b9345402e8">Rect</a> &gt; &amp; </td>
          <td class="paramname"><em>boundingBoxes</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool </td>
          <td class="paramname"><em>showCrosshair</em> = <code>true</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool </td>
          <td class="paramname"><em>fromCenter</em> = <code>false</code> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>boundingBoxes</td><td>=</td><td>cv.selectROIs(</td><td class="paramname">windowName, img[, showCrosshair[, fromCenter]]</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Allows users to select multiple ROIs on the given image. </p>
<p>The function creates a window and allows users to select multiple ROIs using the mouse. Controls: use <code>space</code> or <code>enter</code> to finish current selection and start a new one, use <code>esc</code> to terminate multiple ROI selection process.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">windowName</td><td>name of the window where selection process will be shown. </td></tr>
    <tr><td class="paramname">img</td><td>image to select a ROI. </td></tr>
    <tr><td class="paramname">boundingBoxes</td><td>selected ROIs. </td></tr>
    <tr><td class="paramname">showCrosshair</td><td>if true crosshair of selection rectangle will be shown. </td></tr>
    <tr><td class="paramname">fromCenter</td><td>if true center of selection will match initial mouse position. In opposite case a corner of selection rectangle will correspont to the initial mouse position.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>The function sets it's own mouse callback for specified window using <a class="el" href="../../d7/dfc/group__highgui.html#ga89e7806b0a616f6f1d502bd8c183ad3e" title="Sets mouse handler for the specified window. ">cv::setMouseCallback</a>(windowName, ...). After finish of work an empty callback will be set for the used window. </dd></dl>
</div>
</div>
<a id="ga89e7806b0a616f6f1d502bd8c183ad3e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga89e7806b0a616f6f1d502bd8c183ad3e">◆ </a></span>setMouseCallback()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::setMouseCallback </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="../../d7/dfc/group__highgui.html#gab7aed186e151d5222ef97192912127a4">MouseCallback</a> </td>
          <td class="paramname"><em>onMouse</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void * </td>
          <td class="paramname"><em>userdata</em> = <code>0</code> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Sets mouse handler for the specified window. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window. </td></tr>
    <tr><td class="paramname">onMouse</td><td>Callback function for mouse events. See OpenCV samples on how to specify and use the callback. </td></tr>
    <tr><td class="paramname">userdata</td><td>The optional parameter passed to the callback. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d6/d7f/samples_2cpp_2camshiftdemo_8cpp-example.html#a25">samples/cpp/camshiftdemo.cpp</a>, <a class="el" href="../../db/d75/samples_2cpp_2create_mask_8cpp-example.html#a25">samples/cpp/create_mask.cpp</a>, <a class="el" href="../../d1/d17/samples_2cpp_2ffilldemo_8cpp-example.html#a26">samples/cpp/ffilldemo.cpp</a>, <a class="el" href="../../d8/d34/samples_2cpp_2grabcut_8cpp-example.html#a46">samples/cpp/grabcut.cpp</a>, <a class="el" href="../../d2/d1d/samples_2cpp_2lkdemo_8cpp-example.html#a14">samples/cpp/lkdemo.cpp</a>, <a class="el" href="../../de/dd4/samples_2cpp_2warpPerspective_demo_8cpp-example.html#a14">samples/cpp/warpPerspective_demo.cpp</a>, and <a class="el" href="../../d4/d40/samples_2cpp_2watershed_8cpp-example.html#a24">samples/cpp/watershed.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga7e5437ccba37f1154b65210902fc4480"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7e5437ccba37f1154b65210902fc4480">◆ </a></span>setTrackbarMax()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::setTrackbarMax </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>trackbarname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>maxval</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.setTrackbarMax(</td><td class="paramname">trackbarname, winname, maxval</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Sets the trackbar maximum position. </p>
<p>The function sets the maximum position of the specified trackbar in the specified window.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>[<b>Qt Backend Only</b>] winname can be empty if the trackbar is attached to the control panel.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">trackbarname</td><td>Name of the trackbar. </td></tr>
    <tr><td class="paramname">winname</td><td>Name of the window that is the parent of trackbar. </td></tr>
    <tr><td class="paramname">maxval</td><td>New maximum position. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a32">samples/cpp/falsecolor.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="gabe26ffe8d2b60cc678895595a581b7aa"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gabe26ffe8d2b60cc678895595a581b7aa">◆ </a></span>setTrackbarMin()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::setTrackbarMin </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>trackbarname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>minval</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.setTrackbarMin(</td><td class="paramname">trackbarname, winname, minval</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Sets the trackbar minimum position. </p>
<p>The function sets the minimum position of the specified trackbar in the specified window.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>[<b>Qt Backend Only</b>] winname can be empty if the trackbar is attached to the control panel.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">trackbarname</td><td>Name of the trackbar. </td></tr>
    <tr><td class="paramname">winname</td><td>Name of the window that is the parent of trackbar. </td></tr>
    <tr><td class="paramname">minval</td><td>New minimum position. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a30">samples/cpp/falsecolor.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga67d73c4c9430f13481fd58410d01bd8d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga67d73c4c9430f13481fd58410d01bd8d">◆ </a></span>setTrackbarPos()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::setTrackbarPos </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>trackbarname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>pos</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.setTrackbarPos(</td><td class="paramname">trackbarname, winname, pos</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Sets the trackbar position. </p>
<p>The function sets the position of the specified trackbar in the specified window.</p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>[<b>Qt Backend Only</b>] winname can be empty if the trackbar is attached to the control panel.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">trackbarname</td><td>Name of the trackbar. </td></tr>
    <tr><td class="paramname">winname</td><td>Name of the window that is the parent of trackbar. </td></tr>
    <tr><td class="paramname">pos</td><td>New position. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a33">samples/cpp/falsecolor.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="ga66e4a6db4d4e06148bcdfe0d70a5df27"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga66e4a6db4d4e06148bcdfe0d70a5df27">◆ </a></span>setWindowProperty()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::setWindowProperty </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>prop_id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double </td>
          <td class="paramname"><em>prop_value</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.setWindowProperty(</td><td class="paramname">winname, prop_id, prop_value</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Changes parameters of a window dynamically. </p>
<p>The function setWindowProperty enables changing properties of a window.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window. </td></tr>
    <tr><td class="paramname">prop_id</td><td>Window property to edit. The supported operation flags are: (<a class="el" href="../../d0/d90/group__highgui__window__flags.html#gaeedf4023e777f896ba6b9ffb156f57b8" title="Flags for cv::setWindowProperty / cv::getWindowProperty. ">cv::WindowPropertyFlags</a>) </td></tr>
    <tr><td class="paramname">prop_value</td><td>New value of the window property. The supported flags are: (<a class="el" href="../../d0/d90/group__highgui__window__flags.html#gabf7d2c5625bc59ac130287f925557ac3" title="Flags for cv::namedWindow. ">cv::WindowFlags</a>) </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga56f8849295fd10d0c319724ddb773d96"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga56f8849295fd10d0c319724ddb773d96">◆ </a></span>setWindowTitle()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void cv::setWindowTitle </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>winname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="../../dc/d84/group__core__basic.html#ga1f6634802eeadfd7245bc75cf3e216c2">String</a> &amp; </td>
          <td class="paramname"><em>title</em> </td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>None</td><td>=</td><td>cv.setWindowTitle(</td><td class="paramname">winname, title</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Updates window title. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">winname</td><td>Name of the window. </td></tr>
    <tr><td class="paramname">title</td><td>New title. </td></tr>
  </table>
  </dd>
</dl>
</div>
</div>
<a id="ga2c6ecef4f85d8e5cbefec39c9e82ece0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga2c6ecef4f85d8e5cbefec39c9e82ece0">◆ </a></span>startWindowThread()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::startWindowThread </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.startWindowThread(</td><td class="paramname"></td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
</div>
</div>
<a id="ga5628525ad33f52eab17feebcfba38bd7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga5628525ad33f52eab17feebcfba38bd7">◆ </a></span>waitKey()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::waitKey </td>
          <td>(</td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>delay</em> = <code>0</code></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.waitKey(</td><td class="paramname">[, delay]</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Waits for a pressed key. </p>
<p>The function waitKey waits for a key event infinitely (when \(\texttt{delay}\leq 0\) ) or for delay milliseconds, when it is positive. Since the OS has a minimum time between switching threads, the function will not wait exactly delay ms, it will wait at least delay ms, depending on what else is running on your computer at that time. It returns the code of the pressed key or -1 if no key was pressed before the specified time had elapsed. To check for a key press but not wait for it, use <a class="el" href="../../d7/dfc/group__highgui.html#ga6d20fbd3100ec3badc1eaa653aff99d7" title="Polls for a pressed key. ">pollKey</a>.</p>
<dl class="section note"><dt>Note</dt><dd>The functions <a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7" title="Waits for a pressed key. ">waitKey</a> and <a class="el" href="../../d7/dfc/group__highgui.html#ga6d20fbd3100ec3badc1eaa653aff99d7" title="Polls for a pressed key. ">pollKey</a> are the only methods in HighGUI that can fetch and handle GUI events, so one of them needs to be called periodically for normal event processing unless HighGUI is used within an environment that takes care of event processing.</dd>
<dd>
The function only works if there is at least one HighGUI window created and the window is active. If there are several HighGUI windows, any of them can be active.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">delay</td><td>Delay in milliseconds. 0 is the special value that means "forever". </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Examples: </b></dt><dd><a class="el" href="../../d1/d9e/fld_lines_8cpp-example.html#a13">fld_lines.cpp</a>, <a class="el" href="../../d0/d38/modules_2shape_2samples_2shape_example_8cpp-example.html#a19">modules/shape/samples/shape_example.cpp</a>, <a class="el" href="../../d6/d7f/samples_2cpp_2camshiftdemo_8cpp-example.html#a64">samples/cpp/camshiftdemo.cpp</a>, <a class="el" href="../../de/d01/samples_2cpp_2connected_components_8cpp-example.html#a19">samples/cpp/connected_components.cpp</a>, <a class="el" href="../../da/d32/samples_2cpp_2contours2_8cpp-example.html#a26">samples/cpp/contours2.cpp</a>, <a class="el" href="../../d5/d04/samples_2cpp_2convexhull_8cpp-example.html#a20">samples/cpp/convexhull.cpp</a>, <a class="el" href="../../db/d75/samples_2cpp_2create_mask_8cpp-example.html#a26">samples/cpp/create_mask.cpp</a>, <a class="el" href="../../da/d53/samples_2cpp_2demhist_8cpp-example.html#a27">samples/cpp/demhist.cpp</a>, <a class="el" href="../../d4/dc6/samples_2cpp_2distrans_8cpp-example.html#a24">samples/cpp/distrans.cpp</a>, <a class="el" href="../../d6/d56/samples_2cpp_2edge_8cpp-example.html#a19">samples/cpp/edge.cpp</a>, <a class="el" href="../../d4/d26/samples_2cpp_2facedetect_8cpp-example.html#a19">samples/cpp/facedetect.cpp</a>, <a class="el" href="../../d2/dcf/samples_2cpp_2falsecolor_8cpp-example.html#a34">samples/cpp/falsecolor.cpp</a>, <a class="el" href="../../d1/d17/samples_2cpp_2ffilldemo_8cpp-example.html#a27">samples/cpp/ffilldemo.cpp</a>, <a class="el" href="../../d9/d73/samples_2cpp_2fitellipse_8cpp-example.html#a45">samples/cpp/fitellipse.cpp</a>, <a class="el" href="../../d8/d34/samples_2cpp_2grabcut_8cpp-example.html#a47">samples/cpp/grabcut.cpp</a>, <a class="el" href="../../dd/d93/samples_2cpp_2image_alignment_8cpp-example.html#a52">samples/cpp/image_alignment.cpp</a>, <a class="el" href="../../df/da5/samples_2cpp_2intersectExample_8cpp-example.html#a17">samples/cpp/intersectExample.cpp</a>, <a class="el" href="../../de/d70/samples_2cpp_2kalman_8cpp-example.html#a31">samples/cpp/kalman.cpp</a>, <a class="el" href="../../d9/dde/samples_2cpp_2kmeans_8cpp-example.html#a29">samples/cpp/kmeans.cpp</a>, <a class="el" href="../../d6/ddf/samples_2cpp_2laplace_8cpp-example.html#a27">samples/cpp/laplace.cpp</a>, <a class="el" href="../../d2/d1d/samples_2cpp_2lkdemo_8cpp-example.html#a30">samples/cpp/lkdemo.cpp</a>, <a class="el" href="../../df/dee/samples_2cpp_2minarea_8cpp-example.html#a25">samples/cpp/minarea.cpp</a>, <a class="el" href="../../d3/db0/samples_2cpp_2pca_8cpp-example.html#a31">samples/cpp/pca.cpp</a>, <a class="el" href="../../df/d54/samples_2cpp_2peopledetect_8cpp-example.html#a36">samples/cpp/peopledetect.cpp</a>, <a class="el" href="../../d4/d35/samples_2cpp_2polar_transforms_8cpp-example.html#a36">samples/cpp/polar_transforms.cpp</a>, <a class="el" href="../../d5/de8/samples_2cpp_2segment_objects_8cpp-example.html#a25">samples/cpp/segment_objects.cpp</a>, <a class="el" href="../../db/d00/samples_2cpp_2squares_8cpp-example.html#a33">samples/cpp/squares.cpp</a>, <a class="el" href="../../d0/df8/samples_2cpp_2train_HOG_8cpp-example.html#a20">samples/cpp/train_HOG.cpp</a>, <a class="el" href="../../d9/d47/samples_2cpp_2tutorial_code_2features2D_2Homography_2homography_from_camera_displacement_8cpp-example.html#a27">samples/cpp/tutorial_code/features2D/Homography/homography_from_camera_displacement.cpp</a>, <a class="el" href="../../d0/d92/samples_2cpp_2tutorial_code_2features2D_2Homography_2pose_from_homography_8cpp-example.html#a27">samples/cpp/tutorial_code/features2D/Homography/pose_from_homography.cpp</a>, <a class="el" href="../../dc/dbc/samples_2cpp_2tutorial_code_2HighGUI_2AddingImagesTrackbar_8cpp-example.html#a9">samples/cpp/tutorial_code/HighGUI/AddingImagesTrackbar.cpp</a>, <a class="el" href="../../d8/ded/samples_2cpp_2tutorial_code_2Histograms_Matching_2MatchTemplate_Demo_8cpp-example.html#a8">samples/cpp/tutorial_code/Histograms_Matching/MatchTemplate_Demo.cpp</a>, <a class="el" href="../../d2/dda/samples_2cpp_2tutorial_code_2ImgProc_2basic_drawing_2Drawing_1_8cpp-example.html#a11">samples/cpp/tutorial_code/ImgProc/basic_drawing/Drawing_1.cpp</a>, <a class="el" href="../../de/d06/samples_2cpp_2tutorial_code_2ImgProc_2basic_drawing_2Drawing_2_8cpp-example.html#a6">samples/cpp/tutorial_code/ImgProc/basic_drawing/Drawing_2.cpp</a>, <a class="el" href="../../df/d5e/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_1_8cpp-example.html#a11">samples/cpp/tutorial_code/ImgProc/Morphology_1.cpp</a>, <a class="el" href="../../da/d34/samples_2cpp_2tutorial_code_2ImgProc_2Morphology_2_8cpp-example.html#a9">samples/cpp/tutorial_code/ImgProc/Morphology_2.cpp</a>, <a class="el" href="../../d3/d08/samples_2cpp_2tutorial_code_2ImgProc_2Pyramids_2Pyramids_8cpp-example.html#a5">samples/cpp/tutorial_code/ImgProc/Pyramids/Pyramids.cpp</a>, <a class="el" href="../../d3/d8f/samples_2cpp_2tutorial_code_2ImgProc_2Smoothing_2Smoothing_8cpp-example.html#a22">samples/cpp/tutorial_code/ImgProc/Smoothing/Smoothing.cpp</a>, <a class="el" href="../../d6/d14/samples_2cpp_2tutorial_code_2ImgTrans_2copyMakeBorder_demo_8cpp-example.html#a14">samples/cpp/tutorial_code/ImgTrans/copyMakeBorder_demo.cpp</a>, <a class="el" href="../../d1/de6/samples_2cpp_2tutorial_code_2ImgTrans_2houghcircles_8cpp-example.html#a18">samples/cpp/tutorial_code/ImgTrans/houghcircles.cpp</a>, <a class="el" href="../../d5/df9/samples_2cpp_2tutorial_code_2ImgTrans_2houghlines_8cpp-example.html#a24">samples/cpp/tutorial_code/ImgTrans/houghlines.cpp</a>, <a class="el" href="../../d3/d94/samples_2cpp_2tutorial_code_2ImgTrans_2Sobel_Demo_8cpp-example.html#a18">samples/cpp/tutorial_code/ImgTrans/Sobel_Demo.cpp</a>, <a class="el" href="../../da/d94/samples_2cpp_2tutorial_code_2ml_2introduction_to_pca_2introduction_to_pca_8cpp-example.html#a37">samples/cpp/tutorial_code/ml/introduction_to_pca/introduction_to_pca.cpp</a>, <a class="el" href="../../de/dd9/samples_2cpp_2tutorial_code_2photo_2non_photorealistic_rendering_2npr_demo_8cpp-example.html#a12">samples/cpp/tutorial_code/photo/non_photorealistic_rendering/npr_demo.cpp</a>, <a class="el" href="../../dc/d23/samples_2cpp_2tutorial_code_2photo_2seamless_cloning_2cloning_demo_8cpp-example.html#a15">samples/cpp/tutorial_code/photo/seamless_cloning/cloning_demo.cpp</a>, <a class="el" href="../../df/d94/samples_2cpp_2videowriter_basic_8cpp-example.html#a11">samples/cpp/videowriter_basic.cpp</a>, <a class="el" href="../../de/dd4/samples_2cpp_2warpPerspective_demo_8cpp-example.html#a27">samples/cpp/warpPerspective_demo.cpp</a>, <a class="el" href="../../d4/d40/samples_2cpp_2watershed_8cpp-example.html#a25">samples/cpp/watershed.cpp</a>, <a class="el" href="../../d9/d8d/samples_2dnn_2classification_8cpp-example.html#a22">samples/dnn/classification.cpp</a>, <a class="el" href="../../d6/d39/samples_2dnn_2colorization_8cpp-example.html#a28">samples/dnn/colorization.cpp</a>, <a class="el" href="../../d4/db9/samples_2dnn_2object_detection_8cpp-example.html#a24">samples/dnn/object_detection.cpp</a>, <a class="el" href="../../d7/d4f/samples_2dnn_2openpose_8cpp-example.html#a28">samples/dnn/openpose.cpp</a>, <a class="el" href="../../d4/d88/samples_2dnn_2segmentation_8cpp-example.html#a16">samples/dnn/segmentation.cpp</a>, <a class="el" href="../../db/da4/samples_2dnn_2text_detection_8cpp-example.html#a13">samples/dnn/text_detection.cpp</a>, <a class="el" href="../../d8/d61/samples_2tapi_2hog_8cpp-example.html#a44">samples/tapi/hog.cpp</a>, and <a class="el" href="../../de/dc0/samples_2tapi_2squares_8cpp-example.html#a51">samples/tapi/squares.cpp</a>.</dd>
</dl>
</div>
</div>
<a id="gafa15c0501e0ddd90918f17aa071d3dd0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gafa15c0501e0ddd90918f17aa071d3dd0">◆ </a></span>waitKeyEx()</h2>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int cv::waitKeyEx </td>
          <td>(</td>
          <td class="paramtype">int </td>
          <td class="paramname"><em>delay</em> = <code>0</code></td><td>)</td>
          <td></td>
        </tr>
      </table><table class="python_language"><tr><th colspan="999" style="text-align:left">Python:</th></tr><tr><td style="width: 20px;"></td><td>retval</td><td>=</td><td>cv.waitKeyEx(</td><td class="paramname">[, delay]</td><td>)</td></tr></table>
</div><div class="memdoc">
<p><code>#include &lt;<a class="el" href="../../d4/dd5/highgui_8hpp.html">opencv2/highgui.hpp</a>&gt;</code></p>
<p>Similar to <a class="el" href="../../d7/dfc/group__highgui.html#ga5628525ad33f52eab17feebcfba38bd7" title="Waits for a pressed key. ">waitKey</a>, but returns full key code. </p>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>Key code is implementation specific and depends on used backend: QT/GTK/Win32/etc </p>
</div>
</div>
</div><!-- contents -->
<!-- HTML footer for doxygen 1.8.6-->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Fri Apr 2 2021 11:36:40 for OpenCV by  <a href="http://www.doxygen.org/index.html">
<img alt="doxygen" class="footer" src="../../doxygen.png"/>
</a> 1.8.13
</small></address>
<script type="text/javascript">
//<![CDATA[
addTutorialsButtons();
//]]>
</script>
</body>
</html>
